package com.captjack.websocket;

import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.context.annotation.ComponentScan;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;

/**
 * @author Capt Jack
 * @date 2018/7/24
 */
@SpringBootApplication
@ComponentScan(basePackages = {"com.captjack.websocket"})
@Controller
@RequestMapping(method = {RequestMethod.GET, RequestMethod.POST})
public class WebSocketApplication {

    public static void main(String[] args) {
        SpringApplication.run(WebSocketApplication.class, args);
    }

    @RequestMapping(value = "/")
    public String init() {
        return "index";
    }

}
